<template>
  <div class="home-container">
    <h1 class="app-title">🚀 Vue 微前端演示系统</h1>
    <p class="app-description">
      基于 Webpack Module Federation 的微前端架构实践，点击左侧菜单访问各功能模块
    </p>
    
    <div class="feature-cards">
      <div class="feature-card">
        <h3>🏠 宿主应用</h3>
        <p>提供统一入口和导航，负责加载和管理微应用</p>
      </div>
      <div class="feature-card">
        <h3>👥 用户模块</h3>
        <p>独立开发、部署的远程应用，提供用户管理功能</p>
      </div>
      <div class="feature-card">
        <h3>📦 订单模块</h3>
        <p>独立开发、部署的远程应用，提供订单管理功能</p>
      </div>
    </div>
  </div>
</template>

<script setup>
import { onMounted } from 'vue'

onMounted(() => {
  console.log('加载宿主应用首页')
})
</script>

<style scoped>
.home-container {
  padding: 40px;
  text-align: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  color: white;
}

.app-title {
  font-size: 36px;
  margin-bottom: 20px;
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.app-description {
  font-size: 18px;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.feature-cards {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.feature-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 30px;
  border-radius: 12px;
  width: 280px;
  transition: transform 0.3s, box-shadow 0.3s;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.feature-card h3 {
  font-size: 20px;
  margin-bottom: 15px;
}

.feature-card p {
  font-size: 16px;
  opacity: 0.9;
}
</style>